home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / howtou_2 / form2.frm < prev    next >
Text File  |  1999-08-28  |  4KB  |  107 lines

  1. VERSION 5.00
  2. Begin VB.Form Form1 
  3.    Caption         =   "Form1"
  4.    ClientHeight    =   2265
  5.    ClientLeft      =   60
  6.    ClientTop       =   345
  7.    ClientWidth     =   4245
  8.    LinkTopic       =   "Form1"
  9.    ScaleHeight     =   2265
  10.    ScaleWidth      =   4245
  11.    StartUpPosition =   3  'Windows Default
  12.    Begin VB.CommandButton Command3 
  13.       Caption         =   "Command3"
  14.       Height          =   510
  15.       Left            =   2970
  16.       TabIndex        =   2
  17.       Top             =   585
  18.       Width           =   1185
  19.    End
  20.    Begin VB.CommandButton Command2 
  21.       Caption         =   "Command2"
  22.       Height          =   510
  23.       Left            =   1530
  24.       TabIndex        =   1
  25.       Top             =   585
  26.       Width           =   1185
  27.    End
  28.    Begin VB.CommandButton Command1 
  29.       Caption         =   "Command1"
  30.       Height          =   510
  31.       Left            =   90
  32.       TabIndex        =   0
  33.       Top             =   585
  34.       Width           =   1185
  35.    End
  36.    Begin VB.Label Label2 
  37.       Alignment       =   2  'Center
  38.       BorderStyle     =   1  'Fixed Single
  39.       BeginProperty Font 
  40.          Name            =   "MS Sans Serif"
  41.          Size            =   12
  42.          Charset         =   0
  43.          Weight          =   700
  44.          Underline       =   0   'False
  45.          Italic          =   0   'False
  46.          Strikethrough   =   0   'False
  47.       EndProperty
  48.       ForeColor       =   &H00800080&
  49.       Height          =   420
  50.       Left            =   45
  51.       TabIndex        =   4
  52.       Top             =   1440
  53.       Width           =   4155
  54.    End
  55.    Begin VB.Label Label1 
  56.       Alignment       =   2  'Center
  57.       BorderStyle     =   1  'Fixed Single
  58.       Caption         =   "Test of the Messagebox Deluxe"
  59.       BeginProperty Font 
  60.          Name            =   "MS Sans Serif"
  61.          Size            =   12
  62.          Charset         =   0
  63.          Weight          =   700
  64.          Underline       =   0   'False
  65.          Italic          =   0   'False
  66.          Strikethrough   =   0   'False
  67.       EndProperty
  68.       ForeColor       =   &H00C00000&
  69.       Height          =   420
  70.       Left            =   180
  71.       TabIndex        =   3
  72.       Top             =   45
  73.       Width           =   3885
  74.    End
  75. End
  76. Attribute VB_Name = "Form1"
  77. Attribute VB_GlobalNameSpace = False
  78. Attribute VB_Creatable = False
  79. Attribute VB_PredeclaredId = True
  80. Attribute VB_Exposed = False
  81.  
  82.  
  83. Private Sub Command1_Click()
  84. Label2.Caption = ""
  85. Call MBox(MFormDeluxe, "This is a situation of a very critical nature", "Agree", "", "", 4, "MessageBox Deluxe test 1", 205, 220, 150, "Times New Roman", "MS Sans Serif", 3000, 3000)
  86. ShowAnswer
  87. End Sub
  88.  
  89. Private Sub Command2_Click()
  90. Label2.Caption = ""
  91. Call MBox(MFormDeluxe, "You really want to overwrite these files ?" & vbCr & vbCr & "If you proceed, all data will be lost... ", "Proceed", "Oops !", "", 5, "MessageBox Deluxe test 2", 225, 192, 0, "MS Sans Serif", "Times New Roman", 1000, 5000)
  92. ShowAnswer
  93. End Sub
  94.  
  95. Private Sub Command3_Click()
  96. Label2.Caption = ""
  97. Call MBox(MFormDeluxe, "Do you want to print this file ?" & vbCr & vbCr & "Make sure there's enough paper in your printer before you hit the print-button...", "Print !", "Sorry !", "Can it be ?", 7, "MessageBox Deluxe test 3", 100, 192, 168, "Times New Roman", "Courier", 5000, 4000)
  98. ShowAnswer
  99. End Sub
  100.  
  101. Private Sub ShowAnswer()
  102. If Message(0) = True Then Label2.Caption = "you hit the first button"
  103. If Message(1) = True Then Label2.Caption = "you hit the second button"
  104. If Message(2) = True Then Label2.Caption = "you hit the third button"
  105.  
  106. End Sub
  107.